import React, { Component } from 'react'
import { BrowserRouter,Route, Switch, Redirect} from "react-router-dom"
import Admin from "./pages/Admin"
import Login from "./pages/Login"

export default class App extends Component {
  render() {
    return (
      <BrowserRouter>
        <Switch>
          <Route path="/admin" component={Admin}></Route>
          <Route path="/login" component={Login}></Route>
          <Redirect to="/admin" component={Admin}></Redirect>
        </Switch>
      </BrowserRouter>
    )
  }
}
